package mfuny.ggongal.admin.http;

import mfuny.ggongal.admin.Server;

import org.json.simple.JSONObject;

import com.ibatis.sqlmap.client.SqlMapClient;

public class HttpPolicy {
	SqlMapClient sqlMapper;
	
	public HttpPolicy() throws Exception {
		sqlMapper = Server.getSqlMapper();
	}
	
	//최신 운영정책 내용 가져오기.
	@SuppressWarnings("unchecked")
	public JSONObject getPolicyContent() throws Exception {
		String content = (String) sqlMapper.queryForObject("policy_selectFinalContent", null);
		JSONObject json = new JSONObject();
		json.put("policy", content);
		return json;
	}
}
